<?php
$judul = '';
$link = '';

if($isUpdate==TRUE){
    $judul = 'Edit Profil';
    $link = site_url('admin/profil/update_user/'.$user_id);
    $submit = 'Update';
} else {    
    $judul = 'Tambah Agen';
    $link =  site_url('admin/profil/tambah_user');
    $submit = 'Tambah';
}

?>
<div class="page dashboard">
    <div class="container">
        <div class="row">
                <ul class="span3 nav nav-list menu-sidebar">
                    <div style="margin-bottom:10px;" >Selamat Datang, <?php echo anchor(site_url('admin/dashboard'), $this->session->userdata('username')); ?></div>
                    <li class="aktif"><?php echo anchor(site_url('admin/profil/form_update_user/'.$this->session->userdata('user_id')),'Edit Profil');?></li>
                    <li class=""><?php echo anchor(site_url('admin/listing'),'Kelola Properti');?></li>
                    <?php if($level_user == 1){ ?>
                    <li class=""><?php echo anchor(site_url('admin/profil'),'Kelola Agen');?></li>
                    <li class=""><?php echo anchor(site_url('admin/artikel'),'Kelola Artikel');?></li>
                    <li class=""><?php echo anchor('http://localhost/artyproperty/editor/properti_baru.php','Kelola Properti Baru');?></li>
                    <?php } ?>
                </ul>
            <div class="span9 daftar-listing">                  
                <form method="post" id="input-form" class="form-horizontal" action="<?php echo $link; ?>">
                    <legend><h3><?php echo $judul ?></h3></legend>
                    <div class="control-group">
                        <label class="control-label" for="nama_depan">Nama Depan:</label>
                        <div class="controls">
                            <input type="text" class="input-xlarge" value="<?php echo $nama_depan ?>" name="nama_depan" id="nama_depan">
                        </div>
                    </div>
                    <div class="control-group">
                        <label class="control-label" for="nama_belakang">Nama Belakang:</label>
                        <div class="controls">
                            <input type="text" class="input-xlarge" value="<?php echo $nama_belakang ?>" name="nama_belakang" id="nama_belakang">
                        </div>
                    </div>
                    <div class="control-group">
                        <label class="control-label" for="username">Username:</label>
                        <div class="controls">
                            <input type="text" class="input-xlarge" value="<?php echo $username ?>" name="username" id="username">
                        </div>
                    </div>
                    <div class="control-group">
                        <label class="control-label" for="email">E-mail:</label>
                        <div class="controls">
                            <input type="text" class="input-xlarge" value="<?php echo $email ?>" name="email" id="email">
                        </div>
                    </div>
                    <div class="control-group">
                        <label class="control-label" for="password">Kata Sandi:</label>
                        <div class="controls">
                            <input type="password" class="input-xlarge" value="" name="password" id="password">
                        </div>
                    </div>
                    <div class="control-group">
                        <label class="control-label" for="password_again">Konfirmasi Kata Sandi:</label>
                        <div class="controls">
                            <input type="password" class="input-xlarge" name="password_again" id="password_again">
                        </div>
                    </div>
                    <div class="span4 offset2">
                        <input type="submit" name="SUBMIT"  class="btn btn-primary btn-large span3" value="Submit" />
                    </div>
                </form>
            </div>
        </div>
    </div>
</div>